<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
    <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
</head>
<body>
<div>
    <input type="text" hidden="hidden" id="id" value="${esOrder.id}">
    发货方：<input type="text"  value="${esOrder.enquiryName}"><br>
    收货方：<input type="text"  value="${esOrder.deliverName}"><br>
    详情：<input type="text"  value="${esOrder.orderDetails}"><br>
    商品编号：<input type="text"  value="${esOrder.goodsNum}"><br>
    商品名称：<input type="text"  value="${esOrder.goodsName}"><br>
    进货数量：<input type="text"  value="${esOrder.goodsNumber}"><br>
    备注：<input type="text" value="${esOrder.goodsDetails}"><br>
    <input type="button" onclick="orderOver()" value="【通过】">
    <input type="button" onclick="orderPass()" value="【驳回】">
</div>
</body>
<script type="text/javascript"></script>
<script src="https://cdn.bootcss.com/jquery/3.4.1/jquery.min.js"></script>
<script>
    function orderOver(){
        let id = $("#id").val();
        $.ajax({
            url:"http://localhost:9011/order/order/updateStatus/"+id,
            json:null,
            contentType:"application/json;charset=utf-8",
            type:"post",
            async:false,
            success:function (res){
                alert(res.data.msg);
                location.href = "http://localhost:5173/order"
            },
            error:function (r){
                console.log(r);
            }
        })
    }
</script>
</html>